﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/BlogAdmin.Master" AutoEventWireup="true" CodeBehind="PostCategoryEdit.aspx.cs" Inherits="Press.MVC.Web.Views.BlogAdmin.PostCategoryEdit" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<%= Html.Validation().ValidatorRegistrationScripts() %>
</asp:Content>

<asp:Content ID="indexContent" ContentPlaceHolderID="MainContentPlaceHolder" runat="server">
  <%= ViewData.Model.PostCategory.ID.ToString() %>

 <% using (Html.Form("BlogAdmin", "PostCategorySave", FormMethod.Post, Html.Validation().FormValidation("required"))) { %> 
   
    <%= Html.Hidden("blogid", ViewData.Model.PostCategory.BlogId.ToString())%>
    <%= Html.Hidden("postcategoryid", ViewData.Model.PostCategory.ID.ToString())%>
    
     <table>

            <tr>
                <td>Category:</td>
                <td><%= Html.TextBox("CategoryName", ViewData.Model.PostCategory.Name)%>
                <%= Html.Validation().RequiredValidator("bodyVal", "CategoryName", "You must supply a Category Name.", "required")%>
                </td>
            </tr>
            
        </table>

        <p></p>
     <%= Html.Validation().ValidatorInitializationScripts() %>
    <%= Html.SubmitButton("savepostcategory","Save")%>
    
<%}%>
 
 
</asp:Content>

